const { merge } = require('webpack-merge');
const baseConfig = require('./webpack.config.base.js');
const devConfig = require('./webpack.config.dev.js');
const prodConfig = require('./webpack.config.prod.js');

module.exports = (env, argv) => {
	if (argv.mode === 'development') {
		return merge(baseConfig(env, argv), devConfig(env, argv));
	}

	if (argv.mode === 'production') {
		return merge(baseConfig(env, argv), prodConfig(env, argv));
	}
	// Add production config here if needed
};
